I know codebreaker has a 199 limit on lines of code allowed.
I don't know exactly what the limit on other cheat devices are.

This function requires 1 line for the jump to it,
and at least 1 line for your enable code.
I usually use the JAL in the function scesifsendcmd as a
enable code with 9 as the first digit.  With many games (all?)
you can add "0c" to that address and change it's value from
"03e00008" to "0803ff7c" to make it jump to this function.
01 Setup					= 24 lines
01 Setup is used for everything.
1 for the jump, at least 1 for the enable code.

You now have at least 173 lines to choose what you want to do.


02 Remove Result				= 9 lines



03 Remove Result Jump Changer		= 1 line
  03 Extra Bytes Scan			= 2 lines
  03 Second Scan For Multiple Bits	= 3 lines
  03 Extra Bits Scan			= 3 lines
ALL						= 9 lines



04 First Bytes Scan					= 16 lines
  04 Either Store If Equal/Not Equal		= 1 line
    04 Store If Equal					= 4 lines
    04 Store If Not Equal				= 5 lines
  04 Either Store If Greater/Lesser Than Value	= 4 lines
    04 Store If Lesser Than Value			= 4 lines
    04 Store If Greater Than Value			= 5 lines	
  04 Range Scan					= 12 lines (that doesn't include "Store If Lesser Than Value")
ALL								= 51 lines



05 Extra Bytes Scans						= 8 lines
  05 Didn't Change, Changed, Decreased, Increased	= 3 lines
    05 Either Keep If Value Changed/Didn't Change	= 1 line
      05 Keep If Value Didn't Change			= 4 lines
      05 Keep If Value Changed				= 5 lines
    05 Either keep if value decreased/increase		= 4 lines
      05 Keep If Value Decreased				= 4 lines
      05 Keep If Value Increased				= 5 lines
  05 If equal to value, increased/decreased by ???????? amount" = 6 lines
    05 Keep If Equal To Value					= 5 lines
    05 signed/unsigned value decreased/increased by ? = 4 lines
      05 Keep If Signed Value Increased By ????????	= 4 lines
      05 Keep If Unsigned Value Increased By ????????	= 5 lines
      05 Keep If Signed Value Decreased By ????????	= 5 lines
      05 Keep If Unsigned Value Decreased By ????????	= 5 lines
ALL									= 68 lines



06 First Scan For Only 1 Bit		= 16 lines
07 First Scan For Multiple Bits	= 11 lines
08 Second Scan For Multiple Bits	= 12 lines



09 Extra Bits Scans			= 9 lines
  09 Keep If All Bits Are Off		= 2 lines
  09 Keep If All Bit Are On		= 2 lines
ALL						= 13 lines



10 Reset Currently Selected Result	= 10 lines
11 Cycle Through Results		= 12 lines
12 Apply Old Value (Bytes)		= 7 lines (including store 0)
13 Turn Bits Off				= 9 lines
14 Turn Bits On (Combine Them)	= 8 lines
15 Turn Bits On (Result Only)		= 6 lines
16 Get The Selected Result's Address= 7 lines
17 Get The Last Result's Address	= 7 lines
18 Set Special OR Value To 0001	= 5 lines
19 Set LUI or ORI to 0			= 4 lines
20 Shift Special OR Value To The Next Highest Bit	= 6 lines
21 OR A Lui Or Ori With The Special Or Value		= 7 lines



22 Lui or Ori Selector						= 4 lines
  22 First Bytes Scan First Value				= 7 lines
  22 First Bytes Scan Second Value				= 8 lines
  22 Extra Bytes Scans Value					= 8 lines
  22 Start Scanning Here					= 8 lines
ALL									= 35 lines



23 Scan Signed or Unsigned and Byte Length Modifier	= 7 lines
  23 Either 1 Byte Scan						= 3 lines
    23 Signed							= 6 lines
    23 Unsigned							= 5 lines
  23 Either 2 Byte Scan						= 3 lines
    23 Signed							= 6 lines
    23 Unsigned							= 5 lines
  23 Either 4 Byte Scan						= 2 lines
    23 Signed							= 6 lines
    23 Unsigned							= 5 lines
ALL									= 48 lines





Almost any game should be able to use this as it is.
With any game, you will only need to change 6 lines:
The enable code
The jump address
2 joker lines in "01 Setup"
2 joker lines in "Extra Bits Scans"